import axios from '@/utils/request';
const baseOriginURL = process.env.VUE_APP_BASE_ORIGIN + '/iot_project';

//项目质保期数量比例-统计
const getWarrantyPercent = params => {
  return axios.get(baseOriginURL + '/project/getWarrantyPercent', {
    params
  });
};

//项目设备总量统计
const getDeviceCount = params => {
  return axios.get(baseOriginURL + '/project/getDeviceCount', {
    params
  });
};

//项目设备类型统计
const getCustomerCount = params => {
  return axios.get(baseOriginURL + '/project/getCustomerCount', {
    params
  });
};

//项目总量统计
const getProjectCount = params => {
  return axios.get(baseOriginURL + '/project/getProjectCount', {
    params
  });
};

// 获取地区项目总数
const getAreaProjectCount = params => {
  return axios.get(baseOriginURL + '/project/getAreaProjectCount', {
    params
  });
};

//区域项目总量排行
const getAreaProjectOrder = params => {
  return axios.get(baseOriginURL + '/project/getAreaProjectOrder', {
    params
  });
};

//客户项目总量排行
const getCustomerProjectOrder = params => {
  return axios.get(baseOriginURL + '/project/getCustomerProjectOrder', {
    params
  });
};

//行业项目总量排行
const getIndustryProjectOrder = params => {
  return axios.get(baseOriginURL + '/project/getIndustryProjectOrder', {
    params
  });
};

// 获取具体地图区域的项目总量
const getAreaCustomertCount = params => {
  return axios.get(baseOriginURL + '/project/getAreaCustomertCount', {
    params
  });
};

export {
  getDeviceCount,
  getCustomerCount,
  getWarrantyPercent,
  getCustomerProjectOrder,
  getProjectCount,
  getAreaProjectOrder,
  getIndustryProjectOrder,
  getAreaCustomertCount,
  getAreaProjectCount
};
